<template>
	<view class="tongji-box">
		<view class="fenlei-box">
			<view class="leave_title" style="margin: 20px 15px 10px 4px;height: 22px;line-height: 22px;font-size: 22px;">
				按学院统计
			</view>
			  <uni-collapse>
			  	<uni-collapse-item class="biaoticolor" :title="iterm.college" v-for="(iterm,index) in listVo" :key="index">
						<view class="class-box">
							<view class="class-box-list" @click="tongjilist(itermm.classId)" v-for="(itermm,indexx) in iterm.classBos" :key="indexx">
								<view class="class-box-list-iterm"  v-if="iterm.classBos">{{itermm.className}}</view>
							</view>
						</view>
			  	</uni-collapse-item>
			  </uni-collapse>
		</view>
		
		
	</view>
</template>

<script>
	export default {
		data() {
			return {
				listVo:[]
			}
		},
		onShow() {
			this.reloadRequest();
		},
		methods: {
			tongjilist(classId){
				uni.navigateTo({
					url: '/pages/tongjilist/tongjilist?classId='+classId
				});
			},
			reloadRequest() {
				let _this = this;
				//请求首页数据
				uni.request({
					url: this.baseUrl + "/secretary/sum/searchColleges?satoken="+uni.getStorageSync('satoken'),
					method: 'GET',
					data: {
					},
					withCredentials: true,
					headers: {
						//"content-type": "application/x-www-form-urlencoded",
						// token: localStorage.getItem('token')
					},
					success: res => {
						console.log(res.data.data.vo);
						this.listVo=res.data.data.vo
						
					}
				});
			}
		}
	}
</script>

<style lang="scss">
	@import url(@/static/common.css);
	.tongji-box{
		width: 100%;
		overflow: hidden;
		box-sizing: border-box;
		.tongji-title{
			width: 95%;
			margin: 0 auto;
			margin-top: 20rpx;
			margin-bottom: 20rpx;
		}
		.class-box{
			width: 95%;
			margin: 0 auto;
			display: flex;
			flex-direction: row;
			flex-wrap: wrap;
			//justify-content: space-between;
			box-sizing: border-box;
			margin-bottom: 10rpx;
			
			.class-box-list{
				display: flex;
				width: 33.3%;
				.class-box-list-iterm{
					text-align: center;
					display: flex;
					border: 1rpx solid #999999;
					flex-direction: column;
					justify-content: center;
					align-items: center;
					box-sizing: border-box;
					margin: 10px;
					padding: 1px;
					width: 100px;
					height: 45px;
				}
			}
		}
		.fenlei-box{
			width: 100%;
			overflow: hidden;
			box-sizing: border-box;
			.neirong{
				width: 95%;
				margin: 0 auto;
				display: flex;
				overflow: hidden;
				box-sizing: border-box;
				flex-direction: column;
				padding: 10rpx 0;
				border-bottom: 1rpx solid #999999;
				
				.neirong-top{
					display: flex;
					width: 100%;
					overflow: hidden;
					box-sizing: border-box;
					flex-direction: row;
				}
				.banji{
					text-align: center;
					flex: 7;
				}
				.neirong-bottom{
					display: flex;
					width: 100%;
					overflow: hidden;
					box-sizing: border-box;
					flex-direction: row;
					margin-top: 10rpx;
					.neirong-bottom-left{
						flex: 3;
						overflow: hidden;
						box-sizing: border-box;
						flex-direction:column;
						justify-content: center;
						.shichang{
							flex: 1;
						}
						.shijian{
							flex: 1;
							letter-spacing: 1rpx;
							margin-top: 10rpx;
							
							
						}
					}
					.neirong-bottom-right{ 
						flex: 1;
						overflow: hidden;
						box-sizing: border-box;
						// justify-content: center;
						align-items: center;
						.zhuangtai{
							width: 80%;
							padding: 20rpx 0;
							text-align: center;
							 
							background-color: #f5f5f5;
						}
					}
					
				}
			}
			.neirong:last-child{
				border: none;
			}
			.biaoticolor{
				/deep/ .uni-collapse-item__title-box{
					background-color: #f5f5f5;
				}
				/deep/ .uni-collapse-item__title{
					background-color: #f5f5f5;
				}
				/deep/ .uni-collapse-item__title-text{
					color: #77312A;
					font-size: 36rpx;
				}
				
			}
			
			
		}
		
	}
		
	.fenlei-box{
		/dedp/ .uni-collapse-item__wrap-content .uni-collapse-item--border{
			border-bottom: none;
		}	
	}

</style>
